/*
 * @Description:
 * @Author: admin
 * @Date: 2021-06-08 17:23:31
 * @LastEditors: admin
 * @LastEditTime: 2021-06-08 17:27:31
 */
function Person () {
  Person.prototype.name = "";
  Person.prototype.age = "";
  Person.prototype.job = "";
  Person.prototype.friends = ['tom'];
  Person.prototype.sayName = function () {
    console.log(this.name);
  };
}
var p1 = new Person();
p1.name = "larry"
var p2 = new Person();
p2.name = "tarry"
console.log(p1.friends);
console.log(p2.friends);
p1.friends.push('boss')
console.log(p1.friends);

console.log(p2.friends);